package org.streets.workflow.model;

import org.streets.workflow.model.resource.WFApplication;


/**
 * Tool类型的Task
 */
@SuppressWarnings("serial")
public class WFAutoTask extends WFTask{

    /**
     * 任务所引用的应用程序对象。
     */
    protected WFApplication application = null;

    public WFAutoTask(){
        this.setType(AUTO);
    }

    public WFAutoTask(WFElement parent, String name) {
        super(parent, name);
        this.setType(AUTO);
    }

    /**
     * 返回任务自动执行的Application。只有TOOL类型的任务才有Application。
     * @return
     * @see org.WFApplication.model.reference.Application
     */
    public WFApplication getApplication() {
        return application;
    }

    /**
     * 设置任务自动执行的Application
     * @param application
     * @see org.WFApplication.model.reference.Application
     */
    public void setApplication(WFApplication application) {
        this.application = application;
    }
}
